package org.aurora.module.auth;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.boot.autoconfigure.data.redis.RedisProperties;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.context.annotation.Bean;

/**
 * AuroraAuthApplication
 * <pre>
 * description:
 * create date: 2025-03-15 18:21:27
 * </pre>
 *
 * @author cao.yong
 */
@SpringBootApplication(scanBasePackages = "org.aurora.module.auth")
@EnableDiscoveryClient
public class AuroraAuthApplication {

    private static final Logger log = LoggerFactory.getLogger(AuroraAuthApplication.class);

    public static void main(String[] args) {
        SpringApplication.run(AuroraAuthApplication.class, args);
    }

    @Bean
    CommandLineRunner commandLineRunner(RedisProperties properties) {
        return args -> log.info("Redis server addr: {}", properties.getHost());
    }
}
